import request from '../utils/request'



export class Vip {

   // 分页
   static page= (pageNum, limit) => request({
      url: '/AYC/vips/getlist',
      method: 'GET',
      params: { pageNum, limit}
   })
   static total = () => request({
      url: '/AYC/vips/total',
      method: 'GET'
   })



   static select = (phone) => request({
      url: '/AYC/vips/select',
      method: 'POST',
      data: {
         phone
      }
   })
   static recharge = (obj) => request({
      url: '/AYC/vips/updatare',
      method: 'POST',
      data: {
         id: obj.id,
         petname: obj.petname,
         phone: obj.phone,
         recharge: obj.recharge,
         sex: obj.sex,
         userid: obj.userid
      }
   })

   static add = (obj) => request({
      url: '/AYC/vips/add',
      method: 'POST',
      data: {
         id: obj.id,
         petname: obj.petname,
         phone: obj.phone,
         recharge: obj.recharge,
         sex: obj.sex,
         userid: obj.userid
      }
   })

   static delete = (id) => request({
      url: '/AYC/vips/delete',
      method: 'GET',
      params: {
         id
      }
   })
   static update = (obj) => request({
      url: '/AYC/vips/update',
      method: "POST",
      id: obj.id,
      petname: obj.petname,
      phone: obj.phone,
      recharge: obj.recharge,
      sex: obj.sex,
      userid: obj.userid
   })

   static list = () => request({
      url: "/AYC/vips/list",
      method: "GET",
   })





}